<template>
    <view>
        <view class="smart-page-head">
            <view class="smart-page-head-title">button按钮</view>
        </view>
        <view>
            <button type="primary"></button>
            <button class="btn" type="primary" :loading="isloading" @click="btnSave">页面主操作</button>
            <button type="default" disabled="false">页面次操作</button>
            <button type="warn">警告操作</button>
            <button type="primary" plain="true">镂空按钮</button>
            <button type="primary" size="mini" class="minbutn">mini按钮</button>
        </view>
    </view>
</template>

<script>
    export default{
        data(){
            return{
                isloading: false
            }
        },
        methods:{
            btnSave(){
                this.isloading = true,
                uni.showLoading({
                    title:'数据加载中'
                });
                setInterval(()=>{
                    this.isloading = false;
                    uni.hideLoading();
                }, 5000)
            }
        }
    }
</script>